BasicWorldWindowController

open class BasicWorldWindowController(wwd: WorldWindow) : AbstractWorldWindowController, WorldWindowController, GestureListener

iOS port of the gesture-driven camera controller. Mirrors the Android shape — own a set of recognizers, dispatch TouchEvents, translate gestureStateChanged into camera updates.

Constructors

Link copied to clipboard
constructor(wwd: WorldWindow)

Properties

Link copied to clipboard
val fling: FlingAnimator

Inertial pan animator. Each platform's createFlingScheduler supplies the per-frame clock. The per-frame action dispatches by projection: 2D uses incremental projected-meters math, 3D uses great-circle radians. Picking the right one matters because Mercator metersPerPixel diverges from the 3D radians-on-a-sphere formula away from the equator.

Link copied to clipboard
val pivotAnchor: PivotAnchorState

Shared anchor for pinch / rotate / wheel handlers. Lazy because engine may not be initialized yet at controller-construction time.

Link copied to clipboard
val velocitySampler: ReleaseVelocitySampler

Trailing-window velocity tracker used to seed fling on gesture release.

Functions

Link copied to clipboard
open override fun cancelFling()

Cancels any in-progress inertial pan ("fling"). The host calls this on every touch start before routing the event downstream.

Link copied to clipboard
open override fun gestureStateChanged(event: TouchEvent, recognizer: GestureRecognizer)
Link copied to clipboard
fun handleIndirectPinch(state: GestureState, scale: Float, screenX: Float, screenY: Float)

Programmatic pinch entry for Mac trackpad's native UIPinchGestureRecognizer - UITouch-based PinchRecognizer doesn't see indirect (trackpad) pinches.

Link copied to clipboard
fun handleIndirectRotate(state: GestureState, rotationRadians: Float, screenX: Float, screenY: Float)

Programmatic rotation entry for Mac trackpad's UIRotationGestureRecognizer - UITouch-based RotationRecognizer doesn't see indirect (trackpad) rotations.

Link copied to clipboard
fun handleIndirectTilt(state: GestureState, translationY: Float)

Programmatic tilt entry for Mac trackpad two-finger pan.

Link copied to clipboard
open override fun onTouchEvent(event: TouchEvent): Boolean
Link copied to clipboard
open override fun release()

Releases any platform resources held by the controller (timers, frame callbacks). Subclasses should override and call super.release() to add their own cleanup (e.g. VC repeat timers).